-- spell_bonus
-- created by panyl
-- 进入下一层时，获得xx卷轴效果，非持续类魔法用

return {
    apply = function(prop, baseValue)
        return baseValue + prop[3];
    end,

    -- 进入下一层触发
    trigger = function(who, prop, arg)
        local skillId = tonumber(prop[2]);
        local round = CombatM.getRound();

        SkillM.apply(who, who, skillId, round);

        EventMgr.fire(event.PLAYER_MOVE, -1);

        return true;
    end,

    desc = function(prop)
        local row = PropM.getRow(prop[1]);
        local desc = row.desc;
        local skillName = SkillM.query(tonumber(prop[2]), "name");

        desc = string.gsub(desc, "{0}", skillName);

        return desc;
    end,

    record = function(target, prop, path)
        return false;
    end
};